package shopping.service.impl;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import shopping.dao.ICommonDao;
import shopping.entity.ParentEntity;
import shopping.service.interfaces.ICommonService;

@Service
public class CommonServiceImpl implements ICommonService{

	@Resource
	private ICommonDao commonDao;

	@Override
	public Object queryById(Class<ParentEntity> t, int id) {
		return commonDao.queryById(t, id);
	}

	@Override
	public void save(ParentEntity entity) {
		commonDao.save(entity);
		
	}

	@Override
	public void deleteById(ParentEntity entity) {
		commonDao.deleteById(entity);
		
	}

	@Override
	public void update(ParentEntity entity) {
		commonDao.update(entity);
	}

}
